
Unit multiboot;

Interface

Const 
  KERNEL_STACKSIZE = $4000;

  MULTIBOOT_BOOTLOADER_MAGIC = $2BADB002;

Type 
  Pelf_section_header_table_t = ^elf_section_header_table_t;
  elf_section_header_table_t = packed Record
    num: DWORD;
    size: DWORD;
    addr: DWORD;
    shndx: DWORD;
  End;

  Pmultiboot_info_t = ^multiboot_info_t;
  multiboot_info_t = packed Record
    flags: DWORD;

{The two variables below *can* be declared as a single qword variable, if your compiler supports qwords.}
    mem_lower: DWORD;
    mem_upper: DWORD;
    boot_device: DWORD;
    cmdline: DWORD;
    mods_count: DWORD;
    mods_addr: DWORD;
    elf_sec: elf_section_header_table_t;
    mmap_length: DWORD;
    mmap_addr: DWORD;
  End;

  Pmodule_t = ^module_t;
  module_t = packed Record
    mod_start: DWORD;
    mod_end: DWORD;
    name: DWORD;
    reserved: DWORD;
  End;

  Pmemory_map_t = ^memory_map_t;
  memory_map_t = packed Record
    size: DWORD;
          {Again, you can declare these as a qword.}
    base_addr_low: DWORD;
    base_addr_high: DWORD;
          {And once again, these can be made into one qword variable.}
    length_low: DWORD;
    length_high: DWORD;
    mtype: DWORD;
  End;

  Implementation

End.
